#-*-coding:utf-8-*-
import hou
class Notifications(object):
    def __init__(self):
        super(Notifications,self).__init__()


    def setNotificationArea(self,areaNum):
        '''
        :param areaNum: 0 - Viewport, 1 - Status bar
        :return:
        '''
        hou.setPreference('notify.location.menu', str(areaNum))
        # print('setNotificationArea')

    def getNotificationArea(self):
        hou.getPreference('notify.location.menu')
        # print('getNotificationArea')


    def sethelpTipArea(self,areaNum):
        '''
        :param areaNum: 0 - Viewport, 1 - Status bar , 2 - Suppress
        :return:
        '''
        hou.setPreference('notify.helptip.menu', str(areaNum))
        # print('sethelpTipArea')


    def gethelpTipArea(self):
        return hou.getPreference('notify.helptip.menu')
        # print('gethelpTipArea')



    def setEchoHotkeyCommands(self,bool):
        if bool == True:
            hou.setPreference('notify.echohotkey.val','1')
            # print('1')
        else:
            hou.setPreference('notify.echohotkey.val','0')
            # print('0')

    def getEchoHotkeyCommands(self):
        return hou.getPreference('notify.echohotkey.val')
        # print('getEchoHotkeyCommands')



    def setMessageTimeLimit(self,value):
        hou.setPreference('notify.timelimited.val',str(value))
        # print('setMessageTimeLimit')

    def getMessageTimeLimit(self):
        return hou.getPreference('notify.timelimited.val')
        # print('getMessageTimeLimit')



